{% load static %}
<html>
<head>
    <title>{% block title %}{% endblock %}</title>
    <link rel="stylesheet" href="{% static 'bootstrap/css/bootstrap.min.css' %}"/>
    {% block css %}{% endblock %}
</head>
<style>
    .logo {
        width: 150px;
        height: 150px;
    }
</style>
<body>
<div class="container">
    <div class="row">
        <div class="navbar-header">
            <a class="navbar-brand" href="/">网站名称</a>
        </div>
        <div class="collapse navbar-collapse">
            <ul class="nav nav-tabs navbar-right">
                <li role="presentation"
                '{% if request.path == '/' %}' class="active" '{% endif %}' ><a href="/">首页</a></li>
                <li role="presentation"
                '{% if request.path == '/read' %}' class="active" '{% endif %}' ><a href="/read">图片</a></li>
                <li role="presentation"><a href="#">导航一</a></li>
                <li role="presentation"><a href="#">导航二</a></li>
                {% if request.user.is_authenticated %}
                <li role="presentation" class="dropdown">
                    <a class="dropdown-toggle" data-toggle="dropdown" href="#" role="button" aria-haspopup="true"
                       aria-expanded="false">
                        {{request.user.username}} <span class="caret"></span></a>
                    <ul class="dropdown-menu">
                        <li><a href="{% url 'logout'%}"  tabindex="-1"><span class="glyphicon glyphicon-off"></span> 退出</a></li>
                    </ul>
                </li>
                {% else %}
                <li role="presentation"
                '{% if request.path == '/login' %}' class="active" '{% endif %}'><a href="{% url 'login'%}">登录</a></li>
                <li role="presentation"
                '{% if request.path == '/register' %}' class="active" '{% endif %}'><a
                    href="{% url 'register'%}">注册</a></li>
                {% endif %}
            </ul>
        </div>
    </div>
    <!--<img src="{% static 'images/site.png' %}" alt="Logo" class="logo">-->
    {% block content %}{% endblock %}
</div>
</body>
<script src="{% static 'js/jquery.min.js' %}"></script>
<script src="{% static 'bootstrap/js/bootstrap.min.js' %}"></script>
{% block js %}{% endblock %}
</html>